﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Serialization;
using System.Text;
using WebChatApi.Common.Interface;

namespace WebChatApi.Common
{
    /// <summary>
    /// Class for base content information.
    /// </summary>
    [DataContract]
    [KnownType(typeof(BaseObject))]

    public class BaseContentObject : BaseObject, IIdentifiable
    {
        #region Properties

        /// <summary>
        /// Gets or sets the user key of owner.
        /// </summary>
        /// <value>
        /// The user key.
        /// </value>
        [DataMember]
        public Guid UserKey
        {
            get;
            set;
        }

        /// <summary>
        /// Gets or sets the content.
        /// </summary>
        /// <value>
        /// The content.
        /// </value>
        [DataMember]
        public string Content
        {
            get;
            set;
        }

        /// <summary>
        /// Gets or sets the display name of the user.
        /// </summary>
        /// <value>
        /// The display name of the user.
        /// </value>
        [DataMember]
        public string UserDisplayName
        {
            get;
            set;
        }

        #endregion

        #region Constructor

        /// <summary>
        /// Initializes a new instance of the <see cref="BaseContentObject"/> class.
        /// </summary>
        public BaseContentObject()
        {
            this.Key = Guid.NewGuid();
        }

        #endregion
    }
}
